

var insightState = {
    0: "Draft",    
    1: "Published",
    3: "Unpublished"
}

var collection = db.getSiblingDB("ClientPlatform").Insight
collection.find({State: { $type: 16 }}).forEach(function(item){

    item.State = insightState[item.State];

    collection.save(item);
})

